@import 'element-plus/lib/theme-chalk/el-scrollbar.css';
@import './menu.css';

.pro-layout {
  display: flex;
  height: var(--layout-height);
  overflow: hidden;
  & .pro-container {
    flex: 1;
    display: flex;
    flex-direction: column;
    width: calc(100% - var(--aside-width));
    background: var(--c-page-background);
  }
  & .aside-collapse + .pro-container {
    width: calc(100% - var(--aside-collapse-width));
  }
  & .pro-aside {
    & .mask {
      display: none;
    }
    & .pro-aside-wrapper {
      display: flex;
      flex-direction: column;
      width: var(--aside-width);
      height: 100%;
      border-right: 1px solid var(--c-border);
      background: var(--c-aside-background);
      transition: width var(--t-duration) var(--t-timing-function);
      & .pro-aside-logo {
        padding-left: 20px;
        height: var(--header-height);
        min-height: var(--header-height);
        border-bottom: 1px solid var(--c-border);
        background: var(--c-aside-background);
        overflow: hidden;
      }
      & .el-scrollbar {
        flex: 1;
        & .el-scrollbar__wrap {
          overflow-x: hidden;
        }
      }
    }
    &.aside-collapse .pro-aside-wrapper {
      width: var(--aside-collapse-width);
    }
    @media (--xs-medium) {
      position: absolute;
      left: 0;
      top: 0;
      bottom: 0;
      width: 0;
      z-index: var(--z-index-sidebar);
      &.aside-collapse {
        width: 100%;
      }
      & .mask {
        display: block;
        position: absolute;
        opacity: 0;
        transition: opacity var(--t-duration) var(--t-timing-function);
      }
      &.aside-collapse .mask {
        top: 0;
        bottom: 0;
        left: 0;
        right: 0;
        background: var(--c-mask-background);
        opacity: 1;
      }
      & .pro-aside-wrapper {
        transform: translateX(-100%);
        transition: transform var(--t-duration) var(--t-timing-function);
      }
      &.aside-collapse .pro-aside-wrapper {
        width: var(--aside-width);
        transform: translateX(0);
      }
    }
  }
  & .pro-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 20px;
    height: var(--header-height);
    min-height: var(--header-height);
    border-bottom: 1px solid var(--c-border);
    background: var(--c-header-background);
    & .header-slot {
      display: flex;
      align-items: center;
      & .header-fold-btn {
        display: inline-block;
        margin-right: 20px;
        width: 22px;
        height: 22px;
        cursor: pointer;
      }
    }
  }
  & .pro-main {
    margin: var(--main-margin);
    padding: var(--main-padding);
    border: 1px solid var(--c-border);
    border-radius: var(--border-radius);
    background: var(--c-aside-background);
    &.el-scrollbar .el-scrollbar__wrap {
      margin-bottom: 0 !important;
      overflow-x: hidden;
    }
    @media (--xs-medium) {
      margin: var(--xs-main-margin);
      padding: var(--xs-main-padding);
      &.el-scrollbar .el-scrollbar__wrap {
        margin-right: 0 !important;
      }
    }
  }
}
